// Kony

#pragma once

#include "CoreMinimal.h"
#include "GameplayTagContainer.h"
#include "UObject/Interface.h"
#include "PlayerInterface.generated.h"

// This class does not need to be modified.
UINTERFACE(MinimalAPI)
class UPlayerInterface : public UInterface
{
	GENERATED_BODY()
};

/**
 * 玩家接口类 用于处理玩家属性集操作
 */
class GASC_HUANLING_API IPlayerInterface
{
	GENERATED_BODY()

	// Add interface functions to this class. This is the class that will be inherited to implement this interface.
public:
	//获取升级所需经验值
	UFUNCTION(BlueprintNativeEvent)
	int32 FindLevelForLevelAndXP(int32 InLevel, int32 InXP) const;
	//获取修为值
	UFUNCTION(BlueprintNativeEvent)
	int32 GetXP() const;
	//获取灵气值
	UFUNCTION(BlueprintNativeEvent)
	int32 GetLingQi() const;
	//获取等级
	UFUNCTION(BlueprintNativeEvent)
	int32 GetLevel() const;
	//获取属性点/修炼点数
	UFUNCTION(BlueprintNativeEvent)
	int32 GetAttributePointsReward(int32 Level) const;
	//获取技能点/修为点数
	UFUNCTION(BlueprintNativeEvent)
	int32 GetSpellPointsReward(int32 Level) const;
	//增加修为值
	UFUNCTION(BlueprintNativeEvent)
	void AddToXP(int32 InXP);
	//增加灵气值
	UFUNCTION(BlueprintNativeEvent)
	void AddToLingQi(int32 InLingQi);
	//增加玩家等级
	UFUNCTION(BlueprintNativeEvent)
	void AddToPlayerLevel(int32 InPlayerLevel);
	//增加玩家属性点/修炼点数
	UFUNCTION(BlueprintNativeEvent)
	void AddToAttributePoints(int32 InAttributePoints);
	//获取当前玩家可用属性点/修炼点数
	UFUNCTION(BlueprintNativeEvent)
	int32 GetAttributePoints() const;
	//增加玩家技能点/修为点数
	UFUNCTION(BlueprintNativeEvent)
	void AddToSpellPoints(int32 InSpellPoints);
	//获取当前玩家可用技能点/修为点数
	UFUNCTION(BlueprintNativeEvent)
	int32 GetSpellPoints() const;
	//升级
	UFUNCTION(BlueprintNativeEvent)
	void LevelUp();

	//设置选中目标
	UFUNCTION(BlueprintNativeEvent)
	void SetSelectedTarget(AActor* InSelectedTarget);
	//获取选中目标
	UFUNCTION(BlueprintNativeEvent)
	AActor* GetSelectedTarget() const;
	//清除选中目标
	UFUNCTION(BlueprintNativeEvent)
	void ClearSelectedTarget();

	//显示 鼠标魔法阵
	UFUNCTION(BlueprintNativeEvent, BlueprintCallable)
	void ShowMagicCircle(UMaterialInstance* DecalMaterial = nullptr, FGameplayTag SpellInputTag = FGameplayTag());
	//隐藏 鼠标魔法阵
	UFUNCTION(BlueprintNativeEvent, BlueprintCallable)
	void HideMagicCircle();

	//存储玩家进度函数 - 存档 传入检查点标签
	UFUNCTION(BlueprintNativeEvent, BlueprintCallable)
	void SaveProgress(const FName& CheckpointTag);
};
